package services;

import java.util.ServiceLoader;

/**
 * @description:
 * @author: sali
 * @date: 2025/3/18 下午8:33.
 * @version: 1.0
 */
public class Test {

    public static void main(String[] args) {
        ServiceLoader<Robot> serviceLoader = ServiceLoader.load(Robot.class);
        System.out.println("Java SPI");
        serviceLoader.forEach(Robot::sayHello);
    }

}
